package com.lanou3g.demo;

import java.io.*;

public class Main{
    public static void main(String[] args) throws FileNotFoundException {
        Coffee mocha = new Mocha();
        mocha = new Sugar(mocha);
        mocha = new Milk(mocha);

        mocha = new Sugar(mocha);

        System.out.println(mocha.getName());
        System.out.println(mocha.calculate()+"元");

        InputStream in = new FileInputStream("lsdf");
        InputStreamReader isr = new InputStreamReader(in);
        BufferedReader br = new BufferedReader(isr);


    }
}
